<template>
  <div class="home">
    <img alt="Vue logo" src="../assets/logo.png">
    <HelloWorld :someData.sync="someData" @changeData="changeData"/>
    1<input type="text" :value="someData">
  </div>
</template>

<script>
// @ is an alias to /src
import HelloWorld from '@/components/HelloWorld.vue'
export default {
  name: 'HomeView',
  components: {
    HelloWorld
  },
   data() {
    return {
      someData: "这是父组件传递的数据",
    };
  },
   methods:{
    changeData(){
      console.log('子组件给我传递了一个方法');
    }
  }
}
</script>
